package com.easyban.service;

import java.util.List;

import com.easyban.Dto.FileInfoDto;
import com.easyban.Dto.SessionWebUserDto;
import com.easyban.entity.query.FileInfoQuery;
import com.easyban.entity.po.FileInfo;
import com.easyban.entity.vo.PaginationResultVO;
import com.easyban.entity.vo.UploadResultDto;


/**
 * 文件信息 业务接口
 */
public interface FileInfoService {

	/**
	 * 根据条件查询列表
	 */
	List<FileInfo> findListByParam(FileInfoQuery param);

	/**
	 * 根据条件查询列表
	 */
	Integer findCountByParam(FileInfoQuery param);

	/**
	 * 分页查询
	 */
	PaginationResultVO<FileInfo> findListByPage(FileInfoQuery param);

	/**
	 * 新增
	 */
	Integer add(FileInfo bean);

	/**
	 * 批量新增
	 */
	Integer addBatch(List<FileInfo> listBean);

	/**
	 * 批量新增/修改
	 */
	Integer addOrUpdateBatch(List<FileInfo> listBean);

	/**
	 * 多条件更新
	 */
	Integer updateByParam(FileInfo bean,FileInfoQuery param);

	/**
	 * 多条件删除
	 */
	Integer deleteByParam(FileInfoQuery param);

	/**
	 * 根据FileIdAndUserId查询对象
	 */
	FileInfo getFileInfoByFileIdAndUserId(String fileId,String userId);


	/**
	 * 根据FileIdAndUserId修改
	 */
	Integer updateFileInfoByFileIdAndUserId(FileInfo bean,String fileId,String userId);


	/**
	 * 根据FileIdAndUserId删除
	 */
	Integer deleteFileInfoByFileIdAndUserId(String fileId,String userId);

    UploadResultDto uploadFile(SessionWebUserDto sessionV, FileInfoDto fileInfoDto);
	Long fileSizeByuserId(String Userid);

    void transferFile(String fileId, SessionWebUserDto sessionV);

	FileInfo newFolder(String filePid, String userId, String fileName);

	FileInfo rename(String fileId, String userId, String fileName);

	List<FileInfo> findListByParamAndExclude(String filePid, String currentFileIds);

	void changeFileFolder(String fileIds, String filePid, String userId);

	void removeFile2RecycleBatch(String userId, String fileIds);

	void recoverFileBatch(String userId, String fileIds);

	void delFileBatch(String userId, String fileIds, boolean b);

    void checkRootFilePid(String fileId, String shareUserId, String filePid);

	void saveShare(String fileId, String shareFileIds, String myFolderId, String shareUserId, String userId);
}